/*-------------------------------------------------------------------------

***************** Modification History ***********************************
   @doc
   @module check.h - Header file for check processing functions |
   @end
   
$Log: /SoftPay/SPK2SIM/Source/Include/check.h $ 
 * 
 * 3     2/21/00 2:59p Jim_b4
 * Include file restructuring
 * 
 * 2     1/07/00 9:47a Page_k1
 * remove include of cct
 * 
 * 1     7/19/99 5:30p Jim_b4
 * 
 * 1     7/19/99 4:06p Jim_b4
 * 
 * 2     6/09/99 11:17a Monique_b1
 * Change headers and file names for SP 2000
**************************************************************************

   Copyright (C) 1999 by VeriFone, Inc.

   All rights reserved.  No part of this software may be reproduced,
   transmitted, transcribed, stored in a retrieval system, or translated
   into any language or computer language, in any form or by any means,
   electronic, mechanical, magnetic, optical, chemical, manual or otherwise,
   without the prior written permission of VeriFone, Inc.

---------------------------------------------------------------------------*/


#ifndef VSCHECK_H
#define VSCHECK_H

#include <util.h>

typedef struct TagCheckData
{
    int  inDLNEntryMethod;
    int  inMICREntryMethod;
	char szBirthdate[DATE_SIZE + 1];
	char szStateCode[STATE_CODE_SIZE + 1];
	char szZipCode[ZIP_CODE_SIZE + 1];
	char szCheckNumber[CHECK_NUMBER_SIZE + 1];
	char szCheckAcctNum[CHECK_ACCT_NUM_SIZE + 1];
	char szManualDLN[MANUAL_DLN_SIZE + 1];
	char szMICRNum[MICR_SIZE + 1];
	
} CHECK_DATA_REC;

#define SIZE_CHECK_DATA_REC        sizeof(CHECK_DATA_REC)

#define DLN_SWIPE_TRACK_1       1
#define DLN_SWIPE_TRACK_2       2
#define DLN_SWIPE_TRACK_3       4
#define DLN_MANUAL_ENTRY        8

#define MICR_SWIPE              1
#define MICR_MANUAL             2


/*  begin check reader related defines  */

#define CKRDR_COMM_SIZE             225
#define CR600_COM_1                 1
#define CR600_COM_2                 2
#define CR600_ON                    1
#define CR600_OFF                   0
#define CR600_HNDSHKE_NONE          0
#define CR600_HNDSHKE_SOFTWARE      1
#define CR600_HNDSHKE_CTSRTS        2
#define CR600_CHAR_LENGTH_7         "7"
#define CR600_CHAR_LENGTH_8         "8"

typedef struct CkrdrStruct
{
    int  inBytesInRxPacket;                        /* Num of bytes in RX pkt */
    char szCkrdrRxCommBuf[CKRDR_COMM_SIZE + 1];    /* Buffer area for RX     */

    int  inBytesInTxPacket;                        /* Num of bytes in TX pkt */
    char szCkrdrTxCommBuf[CKRDR_COMM_SIZE + 1];    /* Buffer area for TX     */

} CKRDR_STRUCT;

#define SIZE_CKRDR_STRUCT sizeof(CKRDR_STRUCT)

/*  end check reader related defines  */

#define VAR_FIELD_ATTRIBUTE_BITS		0xE0
#define VAR_ATT_READ_WRITE				0x20
#define VAR_ATT_NO_ACCESS				0x40
#define VAR_ATT_READ_ONLY				0x80



#endif  /* VSCHECK_H */

